SmartDiscover

About

Due to many different services and protocols used in communication software these days, end users are often in doubt how to setup their client applications (email client, mobile synchronization, VoIP client and so on). Administrators need to use various mass-configuration tools or create detailed how-tos for end users.

It is also time consuming and prone to error to configure all server's protocols in the client application. A solution to retrieve all the server's capabilities and supported protocols is required.

SmartDiscover is a mechanism which ensures that as soon as the user enters email and password (every user must know their email address and password) to his client application and authenticated by the server will receive a complete list of available protocols, ports, URLs and server addresses. User can start working immediately with zero configuration required.

Microsoft has implemented AutoDiscover in Exchange Server for Outlook and ActiveSync clients only. IceWarp goes further and extends available applications by its own email client, Outlook Sync plugin, SIP and IM clients, and the Notifier utility. Virtually any protocol settings can be configured using AutoDiscover feature, provided that the corresponding client has AutoDiscover support built-in.

MSDN Links:

http://msdn.microsoft.com/en-us/library/cc433481.aspx

http://msdn.microsoft.com/en-us/library/cc463896.aspx

Test:

https://www.testexchangeconnectivity.com/

How it Works

The client application once supplied with the user's email address will try to contact the server through a set of simple HTTP GET requests, using the domain part of the email address as a basis. If the URL does not exist or failed with an error, the client retries the other URL using the same mechanism until the server's AutoDiscover service can be contacted.

Assuming that you are configuring your server for the domain of icewarpdemo.com, the preset URLs are:

https://autodiscover.icewarpdemo.com/autodiscover/autodiscover.xml

https://icewarpdemo.com/autodiscover/autodiscover.xml

The client will then authenticate by HTTP authentication, using the same email address and password combination and if successful, the server will return the configuration details in the form of an XML formatted plain text file. The client reads the parts corresponding to services it provides, and configures itself without any user's interaction.

Request

  1. SmartDiscover domain attempt

    A client having an email address and password of the user will issue a simple HTTP GET request to:

    https://autodiscover.icewarpdemo.com/autodiscover/autodiscover.xml

    Authentication request should be returned from the server. When authenticated properly via HTTP authentication, an XML response is returned from the server.

  2. Original domain attempt

    If the URL does not exist or failed with an error, the client should retry additional URL using the same mechanism:

    https://icewarpdemo.com/autodiscover/autodiscover.xml

  3. MX query host attempt

    If still not successful, a client may issue a DNS MX query for the domain to list the records that correspond to the server's hostname. It checks all MX records in the order of preference and attempts to contact the same URL as in step #2:

    https://mxhost1/autodiscover/autodiscover.xml

    https://mxhost2/autodiscover/autodiscover.xml

Note: This step is specific to clients developed by IceWarp and does not follow the original Microsoft specification.

Response

Successful response consists of HTTP 200 OK and a Content-Type: text/xml file.

Configuration

  1. The administrator needs to ensure that both of these DNS records exist:
    • DNS A record: autodiscover.icewarpdemo.com (normally it does not exist)

    • DNS A record: icewarpdemo.com (where the domain is the exact hostname of the server where all services are running; normally it does not exist for a plain mail server, but can be already established for web, XMPP or SIP services)

    Use the DNS Tool (System > Connections > General > DNS Tool button) to check your A records (Host address) if the AutoDiscover fails for ActiveSync clients.

    Note: For Notifier and other IceWarp native clients, the records do not have to be established in DNS - these clients will also check the hostname using the MX records, i.e.: if the email is working, Notifier will configure itself without additional DNS changes. However for ActiveSync, one of the A records above must exist.

  2. A non-expired, CA-issued SSL certificate needs to be installed on the server for AutoDiscover to work with iPhone. Windows Mobile requires a non-expired, either self-signed or CA-issued SSL certificate public key to be installed on the device, corresponding to the certificate installed on the server. Otherwise the AutoDiscover will fail due to untrusted connection with the server (and therefore untrusted authentication).

On-server Setup

Figure. Services management: SmartDiscover tab.

Field

Description

Public Hostname

Hostname IP or alias of the server where IceWarp Serverruns.

This field must not be left blank as it is used when IceWarp Server authenticates or introduces itself to another mail server.

This should be the hostname of your IceWarp Server which is registered on DNS.

You may also want to ensure your IceWarp Server's IP address has a PTR record registered as this is a spam-fighting requirement that some receiving mail servers require.

Note: This value is the same as in the Mail > General > Delivery > Public Hostname field. When changed in one field, it is changed within the second one accordingly

SMTP

Hostname or alias of the server where the SMTP service runs

POP3

Hostname or alias of the server where the POP3 service runs

IMAP

Hostname or alias of the server where the IMAP service runs

XMPP

Hostname or alias of the server where the XMPP service runs

SIP

Hostname or alias of the server where the SIP service runs

Standard / TLS/SSL

(for all services)

Select from the list what type of connection a device will use for SmartDiscover (standard v. secured one).

Ports for these services are defined under the System > Services > General tab

Figure. Services management: SmartDiscover tab.

Field

Description

MobileSync (ActiveSync)

URLs of the services running under the HTTP (Control) service. These URLs consist of:

  • Name or alias of the server where the HTTP service runs. These names (aliases) can differ but all have to be aliases of the same server. E.g.: It is possible to use alias webdav.domain.com for the WebDAV service provided that it is valid alias for mail.domain.com.

  • Port number. Number of the port defined for the HTTP service (32000 here); it is possible to use HTTPS (usually with the port number of 32001).

  • Name of the service folder.

    Note: For ActiveSync it is not possible to change this name.

SyncML (OMA DS)

WebDAV & SmartAttach

WebClient

WebAdmin

Free / Busy

Internet Calendar

SMS

Antispam Records

Install

TeamChat API URL

Collaboration API URL

Set New Hostname For All ...

Click the button to open the Server/Hostname dialog where you can set a new hostname for all above fields.

Within the URL section fields, only the relevant address parts are changed, other parts are kept.

Note: Some of the defined URLs are also used internallyIceWarp Server mechanisms – such as IceWarp WebClient's "forgot password" feature (if enabled by an administrator in IceWarp WebClient). Make sure all paths are correctly specified, so that internal mechanisms work as expected.

DNS SRV Records Configuration

For information about DNS Records Configuration, refer to the chapter of the same name in IceWarp Server GUI Reference or follow the link.